package cta

import "time"

// 引擎的类型
const (
	WAITING        = "等待中"
	CANCELLED      = "已撤销"
	TRIGGERED      = "已触发"
	LIVE           = "实盘"
	BACKTESTING    = "回测"
	BAR            = 1
	TICK           = 2
	EVENTLOG       = "eCtaLog"
	EVENTSTRATEGY  = "eCtaStrategy"
	EVENTSTOPORDER = "eCtaStopOrder"

	INTERVALTICK   = time.Millisecond
	INTERVALMINUTE = time.Minute
	INTERVALHOUR   = time.Hour
	INTERVALDAILY  = 24 * time.Hour
)

// StopOrder 停止单的类型
type StopOrder struct {
	Symbol       string
	Direction    string
	Offset       string
	Price        float32
	Volume       float32
	StopOrderId  string
	StrategyName string
	DateTime     time.Time
	Lock         bool
	Net          bool
	OrderIds     []string
	Status       string
}
